import pygame
import sys
#Iniciar pygame
pygame.init()
# configurar la ventana
ancho = 800
alto = 450
ventana = pygame.display.set_mode((ancho, alto))
BLANCO = (255, 255, 255)
#Pintar el fondo de la ventana
ventana.fill(BLANCO)
pygame.display.set_caption("img/street.png")
MaradonaCoca = pygame.image.load("img/street.png")
x,y = 0,0
ventana.blit(MaradonaCoca, [x,y])
pygame.display.flip()
pygame.display.set_caption("img/stick.png")
MaradonaCoca = pygame.image.load("img/stick.png")
x,y = 400,225
ventana.blit(MaradonaCoca, [x,y])
pygame.display.flip()


# Bucle de eventos
while True:
    for event in pygame.event.get():
        if event.type == pygame.QUIT:
           pygame.quit()
           sys.exti()	 
				 
        if event.type == pygame.KEYDOWN :
           if event.key == pygame.K_LEFT:
              ventana.blit(stick, [x,y])
              x = x - 10
              pygame.display.flip()
           if event.key == pygame.K_RIGHT:
              ventana.blit(stick, [x,y])
              x = x - 10
              pygame.display.flip()
           if event.key == pygame.K_DOWN:
              ventana.blit(stick, [x,y])
              x = x - 10
              pygame.display.flip()
           if event.key == pygame.K_UP:
              ventana.blit(stick, [x,y])
              x = x + 10
              pygame.display.flip()
		              
			    
			        
